package com.pxmeta.common.utils;


import java.util.concurrent.LinkedBlockingQueue;
import java.util.concurrent.ThreadPoolExecutor;
import java.util.concurrent.TimeUnit;

/**
 * 用于单线程数据的存储
 */
public class ThreadPoolExecutorUtil {
    private static ThreadPoolExecutor threadPoolExecutor = new ThreadPoolExecutor(10, 10, 5,
            TimeUnit.SECONDS, new LinkedBlockingQueue<>());

    public static void submit(Runnable task) {
        threadPoolExecutor.submit(task);
    }
}
